if exists('b:current_syntax')
    finish
endif

syntax match ipribPartName '\%^.*'
syntax match ipribPartName '\(\_^\n\)\@1<=.*'
syntax match ipribSwitches '^\([+-]\S\+ \)\+'
syntax match ipribSwitches '\(> \)\@2<=\([+-]\S\+ \)\+'
syntax match ipribArrow ' \zs>\ze '
syntax match ipribFormal '\[[^\[\]]*|[^\[\]]*\]'
syntax match ipribGender '\[[^\[\]]*/[^\[\]]*\]'
syntax match ipribInterpolate '{[^{} ]\+|[^{}]*/[^{}]*}'
syntax match ipribEscapeSequence '$[HhSsLlPMD]'

highlight link ipribPartName Underlined
highlight link ipribSwitches Identifier
highlight link ipribArrow Operator
highlight link ipribGender Type
highlight link ipribFormal Type
highlight link ipribInterpolate PreCondit
highlight link ipribEscapeSequence SpecialChar

let b:current_syntax = 'iprib0'
